﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="OrderView.aspx.cs" Inherits="ZLCMS.Web.SystemManage.Basics.MealOrder.OrderView" %>

<%@ Import Namespace ="ZLCMS.Business.Util" %>
<%@ Import Namespace ="ZLCMS.Data.Model" %>

<form id="pageForm" method="post" runat="Server" class="pageForm required-validate"
    onsubmit="return validateCallback(this, navTabAjaxDone);" action="/SystemManage/Basics/MealOrder/OrderView.aspx">

<!-- 需保存的全局变量，提交时URL参数会丢失 -->
<asp:label runat="server" ID="_id" Visible="False" ></asp:label>
<asp:label runat="server" ID="_freshtabid" Visible="False" >刷新列表TAB</asp:label>
    
<div class="pageContent">
    <div class="pageFormContent" layoutH="56">
    
	<div class="panel collapse">
		<h1>订单信息</h1>
		<div>
    	<table class="list" width="100%">
    	<tr>
			<td style="width: 10%;">订单编号：</td>
			<td style="width: 40%"><%= _ordersDB.OrderNo %>
			</td>
			<td style="width: 10%">下单时间：</td>
			<td style="width: 40%"><%= _ordersDB.OrderTime %></td>
        </tr>
    	<%--<tr>
			<td>订单状态：</td>
			<td>   [<%= ParamKit.GetValue("OrderIsConfirmed", _ordersDB.IsConfirmed, "&nbsp;")%>]
				    [<%= ParamKit.GetValue("OrderPayStatus", _ordersDB.PayStatus, "&nbsp;")%>]
				  [<%= ParamKit.GetValue("OrderShippingStatus", _ordersDB.ShippingStatus, "&nbsp;")%>]
				    [<%= ParamKit.GetValue("OrderIsFinish", _ordersDB.IsFinished, "&nbsp;")%>]
				    [<%= ParamKit.GetValue("OrderIsCancel", _ordersDB.IsCancelled, "&nbsp;")%>]
                    </td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
        </tr>--%>
        </table>
        
        <div class="divider"></div>
        
        <table class="list" width="100%" targetType="navTab" asc="asc" desc="desc">
	    <thead>
			<tr>
				<th width="5%" style="display: none">编号</th>
				<th>商品代码</th>
				<th>商品名称</th>
				<th>数量</th>
				<th>商品价格</th>
				<th>单项小计</th>
				<th>是否参与打折</th>
				<%--<th width="5%">操作</th>--%>
			</tr>
		</thead>
		<tbody>
            <asp:repeater runat="server" id="grid">
                <ItemTemplate>
			    <tr target="uid" rel='<%# NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).Id %>'>
				    <td style="display: none"><span><%# NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).Id%></span></td>
				    <td><%# NHibernateKit.GetItem<ShopProductInfo>(Container.DataItem, 1).ProductNo%></td>
				    <td><%# NHibernateKit.GetItem<ShopProductInfo>(Container.DataItem, 1).ProductName%></td>
				    <td><%# NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).Quantity%></td>
				    <td><%# NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).UnitPrice.ToString()%></td>
				    <td><%# NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).TotalPrice.ToString()%></td>
				    <td><%# ParamKit.GetValue("YesNo_10", NHibernateKit.GetItem<ShopOrderProduct>(Container.DataItem, 0).IsDiscount, "&nbsp;")%></td>
				    <%--<td> 
				        <a href="/" target="_blank">查看</a>&nbsp;&nbsp;
				        <a href="#" target="ajaxTodo" title="请确定要删除" warn="请选择一项">删除</a>
				    </td>--%>
			    </tr>
                </ItemTemplate>
            </asp:repeater>
		</tbody>
	</table>
	
        <div class="divider"></div>
    	
    	<table class="list" width="100%">
    	<tr>
			<td style="width: 10%">商品总金额：</td>
			<td style="width: 20%"><%= _ordersDB.TotalPrice.ToString()%> (<%= _ordersDB.Discount %>%)</td>
            <td style="width: 10%">&nbsp;</td>
			<td style="width: 20%">&nbsp;</td>
			<td style="width: 10%">&nbsp;</td>
			<td style="width: 20%">&nbsp;</td>
			
        </tr>
    	<tr>
			<td>订单总金额：</td>
			<td><%= _ordersDB.TotalPrice.ToString()%></td>
			<td colspan="4">
			<asp:TextBox ID="tb_totalprice" runat="server"></asp:TextBox>&nbsp;
			<div class="button"><div class="buttonContent"><button type="submit">修改订单总金额</button></div></div>
			</td>
        </tr>
    	<%--<tr>
			<td>使用预付款金额：</td>
			<td><%= _ordersDB.UseAdvancePayment.ToString()%></td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
			<td>还需付款金额：</td>
			<td style="color:Red"><%= _hxffje.ToString() %></td>
        </tr>--%>
        </table>
		</div>
	</div>
    
	<div class="panel collapse">
		<h1>下单人信息</h1>
		<div>
		
    	<table class="list" width="100%">
    	<tr>
			<td style="width: 8%">下单人姓名：</td>
			<td style="width: 25%"><%= _ordersDB.ReceiverName%></td>
			<td style="width: 8%">用户名：</td>
			<td style="width: 25%"><%= _ordersDB.MemberAccount%></td>
			<td style="width: 8%">联系电话：</td>
			<td style="width: 25%"><%= _ordersDB.ReceiverPhone%></td>
        </tr>
    	<%--<tr>
			<td>到店时间：</td>
			<td><%= %></td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
        </tr>--%>
        </table>
		</div>
	</div>
    
	<%--<div class="panel collapse">
		<h1>收货人信息</h1>
		<div>
    	<table class="list" width="100%">
    	<tr>
			<td style="width: 8%">购货人姓名：</td>
			<td style="width: 25%"><%= _ordersDB.ReceiverName %></td>
			<td style="width: 8%">联系电话：</td>
			<td style="width: 25%"><%= _ordersDB.ReceiverPhone %></td>
			<td style="width: 8%">Email地址：</td>
			<td style="width: 25%"><%= _ordersDB.ReceiverEmail %></td>
        </tr>
    	<tr>
			<td>收货人地址：</td>
			<td><%= _ordersDB.ReceiverAddress %></td>
			<td>邮政编码：</td>
			<td><%= _ordersDB.ReceiverPostalCode %></td>
			<td>&nbsp;</td>
			<td>&nbsp;</td>
        </tr>
        </table>
		</div>
	</div>--%>
    	
	<div class="panel collapse">
		<h1>订单备注</h1>
		<div>
        <%= _ordersDB.Remark %><br />
		<%--<%= _ordersDB.ManageHistory %>--%>
		</div>
	</div>
    	
	<%--<div class="panel collapse">
		<h1>修改订单状态和选择发货执行方 </h1>
		<div>
    	<table class="list" width="100%">
    	<tr>
			<td style="width:20%">修改订单状态为：</td>
			<td style="width:70%">
			    <asp:dropdownlist runat="server" ID="ddl_isconfirmed" width="100px"></asp:dropdownlist>
				<asp:dropdownlist runat="server" ID="ddl_paystatus" width="100px"></asp:dropdownlist>
				<asp:dropdownlist runat="server" ID="ddl_shippingstatus" width="100px"></asp:dropdownlist>
				<asp:dropdownlist runat="server" ID="ddl_orderisfinish" width="100px"></asp:dropdownlist>
				<asp:dropdownlist runat="server" ID="ddl_orderiscancel" width="100px"></asp:dropdownlist>
			</td>
        </tr>
    	<tr>
			<td>附言：</td>
			<td>
				<asp:TextBox ID="tb_glyfy" runat="server" TextMode="MultiLine" rows="5" 
                    Width="500px" ></asp:TextBox>
			</td>
        </tr>
        </table>
		</div>
	</div>--%>
	</div>
        
	<div class="formBar">
		<ul>
			<li><div class="buttonActive"><div class="buttonContent"><button type="submit">保存</button></div></div></li>
			<li><div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div></li>
		</ul>
	</div>  
</div>
</form>